import { UUID } from "crypto";
import sqlCommonColumn from "src/common/sqlCommonColumn";
import { GptGroup } from "src/module/chat-api/entities/gptgroup.entity";
import { Column, Entity, PrimaryColumn, PrimaryGeneratedColumn } from "typeorm";


@Entity()
export class UserEntity  extends sqlCommonColumn{
  @Column()
  username :string 
  @Column()
  password :string
  @Column({default:null})
  phone :string 
  @PrimaryGeneratedColumn('uuid')
  user_uuid :string
  
  @Column({comment:'用户剩余对话次数（gpt3',nullable:true})
  gpt3Times :number=0

  @Column({comment:'用户剩余对话次数（gpt4）'})
  gpt4Times :number=0
  @Column({comment:'图生文次数'})
  ImgToText :number=0
  @Column({comment:'文生图次数'})
  TextToImg :number=0
  @Column({comment:'慢速图生文'})
  SlowTextToImg :number=0
  
  /**Gpt聊天组 */
  groups :GptGroup[]
}

